
package org.icnmasjid.member.service.impl;

import java.util.List;

import org.icnmasjid.member.service.impl.BaseManager;
import org.icnmasjid.member.model.Login;
import org.icnmasjid.member.dao.LoginDao;
import org.icnmasjid.member.service.LoginManager;

public class LoginManagerImpl extends BaseManager implements LoginManager {
    private LoginDao dao;

    /**
     * Set the Dao for communication with the data layer.
     * @param dao
     */
    public void setLoginDao(LoginDao dao) {
        this.dao = dao;
    }

    /**
     * @see org.icnmasjid.member.service.LoginManager#getLogins(org.icnmasjid.member.model.Login)
     */
    public List getLogins(final Login login) {
        return dao.getLogins(login);
    }

    /**
     * @see org.icnmasjid.member.service.LoginManager#getLogin(String id)
     */
    public Login getLogin(final String id) {
        return dao.getLogin(new Integer(id));
    }

    /**
     * @see org.icnmasjid.member.service.LoginManager#saveLogin(Login login)
     */
    public void saveLogin(Login login) {
        dao.saveLogin(login);
    }

    /**
     * @see org.icnmasjid.member.service.LoginManager#removeLogin(String id)
     */
    public void removeLogin(final String id) {
        dao.removeLogin(new Integer(id));
    }
}
